home *** CD-ROM | disk | FTP | other *** search
- 16
- --- RECORDSEPARATOR ---
-
- --- RECORDSEPARATOR ---
- ReadIni
- --- RECORDSEPARATOR ---
- Platform:
- --- RECORDSEPARATOR ---
-
- --- RECORDSEPARATOR ---
- Windows and Macintosh.
- --- RECORDSEPARATOR ---
-
- --- RECORDSEPARATOR ---
- Description:
- --- RECORDSEPARATOR ---
-
- --- RECORDSEPARATOR ---
- baReadIni gets a string from a Windows style ini file.
- --- RECORDSEPARATOR ---
-
- --- RECORDSEPARATOR ---
- Usage:
- --- RECORDSEPARATOR ---
-
- --- RECORDSEPARATOR ---
- Result = baReadIni( Section, Keyname, Default, IniFile )
- --- RECORDSEPARATOR ---
-
- --- RECORDSEPARATOR ---
- Arguments:
- --- RECORDSEPARATOR ---
-
- --- RECORDSEPARATOR ---
- String, String, String, String.
- --- RECORDSEPARATOR ---
- Section is the section name of the ini file.
- --- RECORDSEPARATOR ---
- Keyname is the name of the key
- --- RECORDSEPARATOR ---
- Default is the string that is returned if the file, section or key doesn't exist.
- --- RECORDSEPARATOR ---
- IniFile is the name if the ini file to use.
- --- RECORDSEPARATOR ---
-
- --- RECORDSEPARATOR ---
- Returns:
- --- RECORDSEPARATOR ---
-
- --- RECORDSEPARATOR ---
- String.
- --- RECORDSEPARATOR ---
- Returns the value associated with the Keyname. If the IniFile, Section or Keyname
- --- RECORDSEPARATOR ---
- doesn't exist, then the return will be the Default string.
- --- RECORDSEPARATOR ---
-
- --- RECORDSEPARATOR ---
- Examples:
- --- RECORDSEPARATOR ---
-
- --- RECORDSEPARATOR ---
- Director:
- --- RECORDSEPARATOR ---
- set Name = baReadIni( "CurrentUser", "UserName", "Error", "Userdat.ini" )
- --- RECORDSEPARATOR ---
- Authorware:
- --- RECORDSEPARATOR ---
- Name := baReadIni( "CurrentUser", "UserName", "Error", "Userdat.ini" )
- --- RECORDSEPARATOR ---
-
- --- RECORDSEPARATOR ---
- Notes:
- --- RECORDSEPARATOR ---
-
- --- RECORDSEPARATOR ---
- An entry in a Windows ini file has the following format :
- --- RECORDSEPARATOR ---
- [Section]
- --- RECORDSEPARATOR ---
- Keyname=string
- --- RECORDSEPARATOR ---
- This function will return the string after the equals sign. When using this function,
- --- RECORDSEPARATOR ---
- the Section name you use should not include the square brackets around the
- --- RECORDSEPARATOR ---
- name. The Keyname should not include the equals sign. For example the ini file for
- --- RECORDSEPARATOR ---
- the example above might look something like this
- --- RECORDSEPARATOR ---
- [CurrentUser]
- --- RECORDSEPARATOR ---
- UserName=Gary Smith
- --- RECORDSEPARATOR ---
- Password=mypw
- --- RECORDSEPARATOR ---
- ModulesCompleted=4
- --- RECORDSEPARATOR ---
- The IniFile can be in any directory. On
- --- RECORDSEPARATOR ---
- Windows
- --- RECORDSEPARATOR ---
- , if the full path is not specified the
- --- RECORDSEPARATOR ---
- file will be assumed to be in the Windows directory, on the
- --- RECORDSEPARATOR ---
- Macintosh
- --- RECORDSEPARATOR ---
- it will be
- --- RECORDSEPARATOR ---
- assumed to be in the Preferences folder.
- --- RECORDSEPARATOR ---
- The ini file does not have to have an .ini extension: any extension can be used.
- --- RECORDSEPARATOR ---
- This function returns a maximum of
- --- RECORDSEPARATOR ---
- 32000 characters.
- --- RECORDSEPARATOR ---
-
- --- RECORDSEPARATOR ---
- See also:
- --- RECORDSEPARATOR ---
-
- --- RECORDSEPARATOR ---
- baWriteIni
- --- RECORDSEPARATOR ---
- baFlushIni
- --- RECORDSEPARATOR ---
- baDeleteIniEntry
- --- RECORDSEPARATOR ---
- baDeleteIniSection